SPBCloseDevice
You can use the SPBCloseDevice function to close a sound input device.
FUNCTION SPBCloseDevice (inRefNum: LongInt): OSErr;
inRefNum
- The device reference number of the sound input device to close.
DESCRIPTION
The SPBCloseDevice function closes a device that was previously opened by SPBOpenDevice and whose device reference number is specified in the inRefNum parameter.
SPECIAL CONSIDERATIONS
Because the SPBCloseDevice function moves or purges memory, you should not call it at interrupt time.
ASSEMBLY-LANGUAGE INFORMATION
The trap macro and routine selector for the SPBCloseDevice function are
| Trap macro | Selector |
|---|
| _SoundDispatch | $021C0014 |
RESULT CODES
| noErr | 0 | No error |
| siBadRefNum | -229 | Invalid reference number |